package com.luckcoder.relax.games.domain.vo;

import com.luckcoder.relax.games.domain.RelaxAudioConfig;
import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
import cn.idev.excel.annotation.ExcelProperty;
import org.dromara.common.excel.annotation.ExcelDictFormat;
import org.dromara.common.excel.convert.ExcelDictConvert;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;
import java.util.Date;



/**
 * 音效配置视图对象 relax_audio_config
 *
 * @author zhanghao
 * @date 2025-09-11
 */
@Data
@ExcelIgnoreUnannotated
@AutoMapper(target = RelaxAudioConfig.class)
public class RelaxAudioConfigVo implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 音效ID
     */
    @ExcelProperty(value = "音效ID")
    private Long audioId;

    /**
     * 游戏编码
     */
    @ExcelProperty(value = "游戏编码")
    private String gameCode;

    /**
     * 音效名称
     */
    @ExcelProperty(value = "音效名称")
    private String audioName;

    /**
     * 音效类型（pop爆泡、eliminate消除、background背景、click点击、success成功）
     */
    @ExcelProperty(value = "音效类型", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "p=op爆泡、eliminate消除、background背景、click点击、success成功")
    private String audioType;

    /**
     * 音效URL（网络地址）
     */
    @ExcelProperty(value = "音效URL", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "网=络地址")
    private String audioUrl;

    /**
     * 本地文件路径（备用）
     */
    @ExcelProperty(value = "本地文件路径", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "备=用")
    private String localPath;

    /**
     * 音量（0.00-1.00）
     */
    @ExcelProperty(value = "音量", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "0=.00-1.00")
    private Long volume;

    /**
     * 时长（毫秒）
     */
    @ExcelProperty(value = "时长", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "毫=秒")
    private Long duration;

    /**
     * 文件格式（wav、mp3、ogg、m4a）
     */
    @ExcelProperty(value = "文件格式", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "w=av、mp3、ogg、m4a")
    private String fileFormat;

    /**
     * 失效时备用方案（generate生成音效、toast提示、silent静默）
     */
    @ExcelProperty(value = "失效时备用方案", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "g=enerate生成音效、toast提示、silent静默")
    private String fallbackType;

    /**
     * 权重（用于随机选择）
     */
    @ExcelProperty(value = "权重", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "用=于随机选择")
    private Long weight;

    /**
     * 显示顺序
     */
    @ExcelProperty(value = "显示顺序")
    private Long sortOrder;

    /**
     * 状态（0正常 1停用）
     */
    @ExcelProperty(value = "状态", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "0=正常,1=停用")
    private String status;

    /**
     * 是否启用（0禁用 1启用）
     */
    @ExcelProperty(value = "是否启用", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "0=禁用,1=启用")
    private String isEnabled;

    /**
     * 备注
     */
    @ExcelProperty(value = "备注")
    private String remark;


}
